'''
@-*- coding: utf-8 -*-
@ python：python 3.10
@ 创建人员：Answer-ixiaofang
@ 创建时间：2024/8/16
'''
# import uiautomator2
# from ez_android_automator.client import PublishClient
# from ez_android_automator.bilibili_task import BilibiliPublishVideoTask, BilibiliPhoneLoginTask
#
# client = PublishClient(uiautomator2.connect_usb())
# print(client.dump_xml())
REQUEST_IP = '192.168.3.10'
import requests
import time

def my_task():
    # 这里写入你想要访问的API地址及参数等相关信息

    try:
        requests.get('http://' + REQUEST_IP + ':8000/medias/task/device_task/')
    except Exception as exception :
        print('http service is not start')
    pass

while True:
    my_task()
    time.sleep(10)  # 每隔10秒执行一次任务